package com.itheima;

import com.itheima.common.pojo.Result;
import com.itheima.tokend.TokenException;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

/**
 * @author 86188
 */
@RestControllerAdvice
public class DobalExceptionHander {

    @ExceptionHandler(TokenException.class)
    public Result TokenException(){
        return Result.error("token失效");
    }
}
